package com.tencreat.domain.mall;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.tencreat.common.annotation.Excel;
import com.tencreat.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import java.time.LocalDateTime;


/**
 * 自提订单对象 mall_selfmention_order
 *
 * @author tencreat
 * @date 2022-01-25
 */
@Data
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = true)
@AllArgsConstructor
@NoArgsConstructor
@ApiModel
@TableName("mall_selfmention_order")
public class MallSelfmentionOrder extends BaseEntity<MallSelfmentionOrder> {
    private static final long serialVersionUID = 1L;


    /** id */
    @TableId(type = IdType.AUTO)
    @ApiModelProperty(value = "ID")
    private Long id;


    /** 自提人 */
    @Excel(name = "自提人")
    @ApiModelProperty(value= "自提人")
    @TableField("`name`")
    private String name;


    /** 电话 */
    @Excel(name = "电话")
    @ApiModelProperty(value= "电话")
    @TableField("`phone`")
    private String phone;


    /** 自提时间 */
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "自提时间", width = 30, dateFormat = "yyyy-MM-dd")
    @TableField("`self_mention_time`")
    private LocalDateTime selfMentionTime;


    /** 订单编号 */
    @Excel(name = "订单编号")
    @ApiModelProperty(value= "订单编号")
    @TableField("`order_sn`")
    private String orderSn;


    /** 商品ID */
    @Excel(name = "商品ID")
    @ApiModelProperty(value= "商品ID")
    @TableField("`goods_id`")
    private Long goodsId;
    /** 规格ID */
    @Excel(name = "规格ID")
    @ApiModelProperty(value= "规格ID")
    @TableField("`norms_id`")
    private Long normsId;

    @Excel(name = "是否取件 1 取走 0 未取")
    @ApiModelProperty(value= "是否取件 1 取走 0 未取")
    @TableField("`take`")
    private Long take;

    /** 商品为自提时的核销码 */
    @Excel(name = "核销码")
    @ApiModelProperty(value = "核销码")
    @TableField("`check_number`")
    private String checkNumber;
    /**
     * 自提ID
     */
    @Excel(name = "自提ID")
    @ApiModelProperty(value = "自提ID")
    @TableField("`selfmention_id`")
    private Long selfmentionId;

}
